home *** CD-ROM | disk | FTP | other *** search
- Path: colossus.holonet.net!russell
- From: russell@news.mdli.com (Russell Blackadar)
- Newsgroups: comp.lang.c++
- Subject: Re: Help- pointers to functions
- Date: 20 Jan 1996 03:44:40 GMT
- Organization: HoloNet National Internet Access System: 510-704-1058/modem
- Distribution: world
- Message-ID: <4dpof8$ejt@colossus.holonet.net>
- References: <4djcn5$hfe@matrix.mdn.com> <NITIN.96Jan19100526@more.eng.sun.com>
- NNTP-Posting-Host: jubal.mdli.com
- X-Newsreader: TIN [version 1.2 PL2]
-
- Nitin More [CONTRACTOR] (nitin@more.eng.sun.com) wrote:
-
- : typedef int (*FunctionType)(const char *str);
-
- : Here you have defined a new type called FunctionType which is a pointer to a
- : function which takes const char* as an argument and returns an int. Now you
- : can define the array as follows:
-
- : FunctionType *functionArray[100];
-
- Well, not quite -- you need to omit the "*" because it's already
- in your typedef.
-
- --
- Russell Blackadar, russell@mdli.com
-